package DesignPrinciple.DepInversion;

public class ComputerDemo {
    public static void main(String[] args) {
        XiJieHardDisk hardDisk = new XiJieHardDisk();
        IntelCPU cpu = new IntelCPU();
        KingStonMemory memory = new KingStonMemory();

        Computer computer = new Computer();

        computer.setCpu(cpu);
        computer.setMemory(memory);
        computer.setHardDisk(hardDisk);

        computer.run();
    }
}
